mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-24 00:31:34 +11:00
add deprecation for old names
This commit is contained in:
parent
b75481b88e
commit
94a8e2d4c3
|
@ -92,6 +92,13 @@ impl ObjectDistribution {
|
||||||
unsafe { initilise_oam() };
|
unsafe { initilise_oam() };
|
||||||
OamManaged::new()
|
OamManaged::new()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// The old name for [`get_managed`][ObjectDistribution::get_managed] kept around for easier migration.
|
||||||
|
/// This will be removed in a future release.
|
||||||
|
#[deprecated = "use get_managed to get the managed oam instead"]
|
||||||
|
pub fn get(&mut self) -> OamManaged<'_> {
|
||||||
|
self.get_managed()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[non_exhaustive]
|
#[non_exhaustive]
|
||||||
|
|
|
@ -26,6 +26,11 @@ use super::DISPLAY_CONTROL;
|
||||||
|
|
||||||
const OBJECT_ATTRIBUTE_MEMORY: *mut u16 = 0x0700_0000 as *mut u16;
|
const OBJECT_ATTRIBUTE_MEMORY: *mut u16 = 0x0700_0000 as *mut u16;
|
||||||
|
|
||||||
|
#[deprecated = "use OamManaged directly instead"]
|
||||||
|
/// The old name for [`OamManaged`] kept around for easier migration.
|
||||||
|
/// This will be removed in a future release.
|
||||||
|
pub type ObjectController<'a> = OamManaged<'a>;
|
||||||
|
|
||||||
pub(super) unsafe fn initilise_oam() {
|
pub(super) unsafe fn initilise_oam() {
|
||||||
for i in 0..128 {
|
for i in 0..128 {
|
||||||
let ptr = (OBJECT_ATTRIBUTE_MEMORY).add(i * 4);
|
let ptr = (OBJECT_ATTRIBUTE_MEMORY).add(i * 4);
|
||||||
|
|
Loading…
Reference in a new issue